#include<iostream>
#include<stdio.h>
#include<stdlib.h>
#include "G:\Projects\None's WorkBentch\DataStructure\head\types.h"

struct SSqList
{
	elemType data[INITSIZE];
	int length;
};

status InitList(SSqList *L)
{
	L->length = 0;
	return OK;
}

status InsertList(SSqList *L, int i, elemType e)
{
	int j;
	if (i<1 || i>L->length+1)
	{
		printf("Insert Position ERROR!");
		return ERROR;
	}
	if (L->length >= INITSIZE)
	{
		printf("overflow");
		exit(OVERFLOW);
	}
	for (j = L->length-1;j != i-2; --j)
	{
		L->data[j+1] = L->data[j];
	}
	j = j<0?0:j;
	L->data[j] = e;
	L->length++;
	return OK;
}
status testSSQL()
{
	SSqList l;
	InitList(&l);
	InsertList(&l, 1, 3);
	printf("%d,%d", l.length, l.data[0]);
	return OK;
}
